﻿package FP 
{
	/**
	 * ...
	 * @author Ty Kimmey
	 */
	
	import com.as3toolkit.ui.Keyboarder;
	import flash.display.MovieClip;
    import flash.ui.Keyboard;
	import flash.geom.Point;
	 
	public class Rhino extends GameElement 
	{
		protected var rWidth:int = 54.5;
		
		
		public function Rhino(aGame:Game) 
		{
			super(aGame);
			//init();
		}
		
		public function init()
		{
			y = stage.stageHeight - 230;
			x = stage.stageWidth * .5;
		}
		
		public function move():void
		{
			if (Keyboarder.keyIsDown(Keyboard.LEFT) && this.x - speed > 0)
			{
				this.x -= speed;
			}			
			else if (Keyboarder.keyIsDown(Keyboard.RIGHT) && this.x + rWidth + speed < stage.stageWidth)
			{
				this.x += speed;
			}
		}		
	}

}